package com.lzc.service;

import com.lzc.listener.StartEvent;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.ApplicationEventPublisher;
import org.springframework.stereotype.Service;

import java.util.EventListener;

@Service
public class ListenerServiceImpl {

    @Autowired
    private ApplicationEventPublisher applicationEventPublisher;

    public void sendStartEvent(StartEvent startEvent){
        applicationEventPublisher.publishEvent(startEvent);
    }
}
